<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="/WEB-INF/views/commons/taglibs.jsp"%>
<%@ taglib prefix="sys" tagdir="/WEB-INF/tags" %>

<html>
<head>
    <title>角色添加页面</title>
  <jsp:include page="../../../commons/common-add.jsp"></jsp:include>
  <script type="text/javascript" src="${basePath}/statics/modules/sys/role/js/role_add.js"></script>
  <link href="${basePath}/statics/modules/sys/role/css/role_add.css" type="text/css" rel="stylesheet"/>

</head>
<body>
  <sys:message msgContent="${message}"/>
    <div class="box-body" >
        <form id="inputForm" action="role_save" method="post"  class="form-horizontal ">
          <input type="hidden" id="id" name="id" value="${ empty role.id ? 0 :role.id}"/>
          <div class="top-form-element-margin">
          <div class="row form-group line-height-34">
            <label for="roleName" class="col-sm-3 control-label text-pull-right" >
              <b style="color:red;">*</b>
              角色名称:
            </label>
            <div class="col-sm-4">
              <input type="text" autofocus class="required form-control" style="display: inline;" id="roleName" name="roleName"   value="${role.roleName}">
            </div>
          </div>

          <div class="row form-group line-height-34">
            <label for="permIds" class="col-sm-3 control-label text-pull-right" >功能权限:</label>
            <div class="col-sm-4">
              <sys:treeselect  id="permIds" name="permIds" value="${selPermIds}" labelName="${selPermNames}"
                               labelValue="${selPermNames}"	title="功能权限"
                               url="/admin/sys/menu/ajax_power_menutree" cssClass="form-control" cssStyle="display: inline;" checked="true"/>
            </div>
          </div>

          <div class="row form-group line-height-34">
            <label  class="col-sm-3 control-label text-pull-right" >是否可用:</label>
            <div class="col-sm-4">
              <input type="radio"  class="minimal  {required:true} " ${empty role.isshow || role.isshow == 0 ? 'checked':''}  name="isshow" id="isshow" value="0"   />启用
              <input type="radio"  class="minimal "  name="isshow" id="isshow1" value="1"   ${ role.isshow == 1 ? 'checked':''}  }/>禁用
            </div>
          </div>

          <div class="row form-group line-height-34">
            <label for="remark" class="col-sm-3 control-label text-pull-right" >备注:</label>
            <div class="col-sm-4">
              <textarea  id="remark" style="display: inline;"  class="form-control"  name="remark"  cols="40" rows="5"></textarea>
            </div>
          </div>

            <div class="row form-group line-height-34" style="text-align: center;">
              <shiro:hasPermission name="sys:role:save">
                <input id="btnSubmit" class="btn btn-primary"  type="submit"
                       value="保存" />&nbsp;
              </shiro:hasPermission>
              <input id="btnCancel" class="btn btn-cancle" style="margin-left: 50px" type="reset" value="重置" />
            </div>
          </div>
        </form>
      </div>
</body>
</html>
